Optimal. Leaf size=414 \[ -\frac {3 b f k n x^m (g x)^{-2 m}}{4 e g m^2}-\frac {b f^2 k n x^{2 m} (g x)^{-2 m} \log (x)}{4 e^2 g m}+\frac {b f^2 k n x^{2 m} (g x)^{-2 m} \log ^2(x)}{4 e^2 g}-\frac {f k x^m (g x)^{-2 m} \left (a+b \log \left (c x^n\right )\right )}{2 e g m}-\frac {f^2 k x^{2 m} (g x)^{-2 m} \log (x) \left (a+b \log \left (c x^n\right )\right )}{2 e^2 g}+\frac {b f^2 k n x^{2 m} (g x)^{-2 m} \log \left (e+f x^m\right )}{4 e^2 g m^2}-\frac {b f^2 k n x^{2 m} (g x)^{-2 m} \log \left (-\frac {f x^m}{e}\right ) \log \left (e+f x^m\right )}{2 e^2 g m^2}+\frac {f^2 k x^{2 m} (g x)^{-2 m} \left (a+b \log \left (c x^n\right )\right ) \log \left (e+f x^m\right )}{2 e^2 g m}-\frac {b n (g x)^{-2 m} \log \left (d \left (e+f x^m\right )^k\right )}{4 g m^2}-\frac {(g x)^{-2 m} \left (a+b \log \left (c x^n\right )\right ) \log \left (d \left (e+f x^m\right )^k\right )}{2 g m}-\frac {b f^2 k n x^{2 m} (g x)^{-2 m} \text {Li}_2\left (1+\frac {f x^m}{e}\right )}{2 e^2 g m^2} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.32, antiderivative size = 414, normalized size of antiderivative = 1.00, number of steps
used = 16, number of rules used = 12, integrand size = 32, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.375, Rules used = {2505, 20,
272, 46, 2423, 30, 19, 2338, 2504, 2441, 2352, 16} \begin {gather*} -\frac {b f^2 k n x^{2 m} (g x)^{-2 m} \text {PolyLog}\left (2,\frac {f x^m}{e}+1\right )}{2 e^2 g m^2}-\frac {(g x)^{-2 m} \left (a+b \log \left (c x^n\right )\right ) \log \left (d \left (e+f x^m\right )^k\right )}{2 g m}-\frac {f^2 k x^{2 m} \log (x) (g x)^{-2 m} \left (a+b \log \left (c x^n\right )\right )}{2 e^2 g}+\frac {f^2 k x^{2 m} (g x)^{-2 m} \log \left (e+f x^m\right ) \left (a+b \log \left (c x^n\right )\right )}{2 e^2 g m}-\frac {f k x^m (g x)^{-2 m} \left (a+b \log \left (c x^n\right )\right )}{2 e g m}-\frac {b n (g x)^{-2 m} \log \left (d \left (e+f x^m\right )^k\right )}{4 g m^2}+\frac {b f^2 k n x^{2 m} (g x)^{-2 m} \log \left (e+f x^m\right )}{4 e^2 g m^2}-\frac {b f^2 k n x^{2 m} (g x)^{-2 m} \log \left (-\frac {f x^m}{e}\right ) \log \left (e+f x^m\right )}{2 e^2 g m^2}+\frac {b f^2 k n x^{2 m} \log ^2(x) (g x)^{-2 m}}{4 e^2 g}-\frac {b f^2 k n x^{2 m} \log (x) (g x)^{-2 m}}{4 e^2 g m}-\frac {3 b f k n x^m (g x)^{-2 m}}{4 e g m^2} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 16
Rule 19
Rule 20
Rule 30
Rule 46
Rule 272
Rule 2338
Rule 2352
Rule 2423
Rule 2441
Rule 2504
Rule 2505
Rubi steps
\begin {align*} \int (g x)^{-1-2 m} \left (a+b \log \left (c x^n\right )\right ) \log \left (d \left (e+f x^m\right )^k\right ) \, dx &=-\frac {f k x^m (g x)^{-2 m} \left (a+b \log \left (c x^n\right )\right )}{2 e g m}-\frac {f^2 k x^{2 m} (g x)^{-2 m} \log (x) \left (a+b \log \left (c x^n\right )\right )}{2 e^2 g}+\frac {f^2 k x^{2 m} (g x)^{-2 m} \left (a+b \log \left (c x^n\right )\right ) \log \left (e+f x^m\right )}{2 e^2 g m}-\frac {(g x)^{-2 m} \left (a+b \log \left (c x^n\right )\right ) \log \left (d \left (e+f x^m\right )^k\right )}{2 g m}-(b n) \int \left (-\frac {f k x^{-1+m} (g x)^{-2 m}}{2 e g m}-\frac {f^2 k x^{-1+2 m} (g x)^{-2 m} \log (x)}{2 e^2 g}+\frac {f^2 k x^{-1+2 m} (g x)^{-2 m} \log \left (e+f x^m\right )}{2 e^2 g m}-\frac {(g x)^{-2 m} \log \left (d \left (e+f x^m\right )^k\right )}{2 g m x}\right ) \, dx\\ &=-\frac {f k x^m (g x)^{-2 m} \left (a+b \log \left (c x^n\right )\right )}{2 e g m}-\frac {f^2 k x^{2 m} (g x)^{-2 m} \log (x) \left (a+b \log \left (c x^n\right )\right )}{2 e^2 g}+\frac {f^2 k x^{2 m} (g x)^{-2 m} \left (a+b \log \left (c x^n\right )\right ) \log \left (e+f x^m\right )}{2 e^2 g m}-\frac {(g x)^{-2 m} \left (a+b \log \left (c x^n\right )\right ) \log \left (d \left (e+f x^m\right )^k\right )}{2 g m}+\frac {\left (b f^2 k n\right ) \int x^{-1+2 m} (g x)^{-2 m} \log (x) \, dx}{2 e^2 g}+\frac {(b n) \int \frac {(g x)^{-2 m} \log \left (d \left (e+f x^m\right )^k\right )}{x} \, dx}{2 g m}+\frac {(b f k n) \int x^{-1+m} (g x)^{-2 m} \, dx}{2 e g m}-\frac {\left (b f^2 k n\right ) \int x^{-1+2 m} (g x)^{-2 m} \log \left (e+f x^m\right ) \, dx}{2 e^2 g m}\\ &=-\frac {f k x^m (g x)^{-2 m} \left (a+b \log \left (c x^n\right )\right )}{2 e g m}-\frac {f^2 k x^{2 m} (g x)^{-2 m} \log (x) \left (a+b \log \left (c x^n\right )\right )}{2 e^2 g}+\frac {f^2 k x^{2 m} (g x)^{-2 m} \left (a+b \log \left (c x^n\right )\right ) \log \left (e+f x^m\right )}{2 e^2 g m}-\frac {(g x)^{-2 m} \left (a+b \log \left (c x^n\right )\right ) \log \left (d \left (e+f x^m\right )^k\right )}{2 g m}+\frac {(b n) \int (g x)^{-1-2 m} \log \left (d \left (e+f x^m\right )^k\right ) \, dx}{2 m}+\frac {\left (b f^2 k n x^{2 m} (g x)^{-2 m}\right ) \int \frac {\log (x)}{x} \, dx}{2 e^2 g}+\frac {\left (b f k n x^{2 m} (g x)^{-2 m}\right ) \int x^{-1-m} \, dx}{2 e g m}-\frac {\left (b f^2 k n x^{2 m} (g x)^{-2 m}\right ) \int \frac {\log \left (e+f x^m\right )}{x} \, dx}{2 e^2 g m}\\ &=-\frac {b f k n x^m (g x)^{-2 m}}{2 e g m^2}+\frac {b f^2 k n x^{2 m} (g x)^{-2 m} \log ^2(x)}{4 e^2 g}-\frac {f k x^m (g x)^{-2 m} \left (a+b \log \left (c x^n\right )\right )}{2 e g m}-\frac {f^2 k x^{2 m} (g x)^{-2 m} \log (x) \left (a+b \log \left (c x^n\right )\right )}{2 e^2 g}+\frac {f^2 k x^{2 m} (g x)^{-2 m} \left (a+b \log \left (c x^n\right )\right ) \log \left (e+f x^m\right )}{2 e^2 g m}-\frac {b n (g x)^{-2 m} \log \left (d \left (e+f x^m\right )^k\right )}{4 g m^2}-\frac {(g x)^{-2 m} \left (a+b \log \left (c x^n\right )\right ) \log \left (d \left (e+f x^m\right )^k\right )}{2 g m}+\frac {(b f k n) \int \frac {x^{-1+m} (g x)^{-2 m}}{e+f x^m} \, dx}{4 g m}-\frac {\left (b f^2 k n x^{2 m} (g x)^{-2 m}\right ) \text {Subst}\left (\int \frac {\log (e+f x)}{x} \, dx,x,x^m\right )}{2 e^2 g m^2}\\ &=-\frac {b f k n x^m (g x)^{-2 m}}{2 e g m^2}+\frac {b f^2 k n x^{2 m} (g x)^{-2 m} \log ^2(x)}{4 e^2 g}-\frac {f k x^m (g x)^{-2 m} \left (a+b \log \left (c x^n\right )\right )}{2 e g m}-\frac {f^2 k x^{2 m} (g x)^{-2 m} \log (x) \left (a+b \log \left (c x^n\right )\right )}{2 e^2 g}-\frac {b f^2 k n x^{2 m} (g x)^{-2 m} \log \left (-\frac {f x^m}{e}\right ) \log \left (e+f x^m\right )}{2 e^2 g m^2}+\frac {f^2 k x^{2 m} (g x)^{-2 m} \left (a+b \log \left (c x^n\right )\right ) \log \left (e+f x^m\right )}{2 e^2 g m}-\frac {b n (g x)^{-2 m} \log \left (d \left (e+f x^m\right )^k\right )}{4 g m^2}-\frac {(g x)^{-2 m} \left (a+b \log \left (c x^n\right )\right ) \log \left (d \left (e+f x^m\right )^k\right )}{2 g m}+\frac {\left (b f^3 k n x^{2 m} (g x)^{-2 m}\right ) \text {Subst}\left (\int \frac {\log \left (-\frac {f x}{e}\right )}{e+f x} \, dx,x,x^m\right )}{2 e^2 g m^2}+\frac {\left (b f k n x^{2 m} (g x)^{-2 m}\right ) \int \frac {x^{-1-m}}{e+f x^m} \, dx}{4 g m}\\ &=-\frac {b f k n x^m (g x)^{-2 m}}{2 e g m^2}+\frac {b f^2 k n x^{2 m} (g x)^{-2 m} \log ^2(x)}{4 e^2 g}-\frac {f k x^m (g x)^{-2 m} \left (a+b \log \left (c x^n\right )\right )}{2 e g m}-\frac {f^2 k x^{2 m} (g x)^{-2 m} \log (x) \left (a+b \log \left (c x^n\right )\right )}{2 e^2 g}-\frac {b f^2 k n x^{2 m} (g x)^{-2 m} \log \left (-\frac {f x^m}{e}\right ) \log \left (e+f x^m\right )}{2 e^2 g m^2}+\frac {f^2 k x^{2 m} (g x)^{-2 m} \left (a+b \log \left (c x^n\right )\right ) \log \left (e+f x^m\right )}{2 e^2 g m}-\frac {b n (g x)^{-2 m} \log \left (d \left (e+f x^m\right )^k\right )}{4 g m^2}-\frac {(g x)^{-2 m} \left (a+b \log \left (c x^n\right )\right ) \log \left (d \left (e+f x^m\right )^k\right )}{2 g m}-\frac {b f^2 k n x^{2 m} (g x)^{-2 m} \text {Li}_2\left (1+\frac {f x^m}{e}\right )}{2 e^2 g m^2}+\frac {\left (b f k n x^{2 m} (g x)^{-2 m}\right ) \text {Subst}\left (\int \frac {1}{x^2 (e+f x)} \, dx,x,x^m\right )}{4 g m^2}\\ &=-\frac {b f k n x^m (g x)^{-2 m}}{2 e g m^2}+\frac {b f^2 k n x^{2 m} (g x)^{-2 m} \log ^2(x)}{4 e^2 g}-\frac {f k x^m (g x)^{-2 m} \left (a+b \log \left (c x^n\right )\right )}{2 e g m}-\frac {f^2 k x^{2 m} (g x)^{-2 m} \log (x) \left (a+b \log \left (c x^n\right )\right )}{2 e^2 g}-\frac {b f^2 k n x^{2 m} (g x)^{-2 m} \log \left (-\frac {f x^m}{e}\right ) \log \left (e+f x^m\right )}{2 e^2 g m^2}+\frac {f^2 k x^{2 m} (g x)^{-2 m} \left (a+b \log \left (c x^n\right )\right ) \log \left (e+f x^m\right )}{2 e^2 g m}-\frac {b n (g x)^{-2 m} \log \left (d \left (e+f x^m\right )^k\right )}{4 g m^2}-\frac {(g x)^{-2 m} \left (a+b \log \left (c x^n\right )\right ) \log \left (d \left (e+f x^m\right )^k\right )}{2 g m}-\frac {b f^2 k n x^{2 m} (g x)^{-2 m} \text {Li}_2\left (1+\frac {f x^m}{e}\right )}{2 e^2 g m^2}+\frac {\left (b f k n x^{2 m} (g x)^{-2 m}\right ) \text {Subst}\left (\int \left (\frac {1}{e x^2}-\frac {f}{e^2 x}+\frac {f^2}{e^2 (e+f x)}\right ) \, dx,x,x^m\right )}{4 g m^2}\\ &=-\frac {3 b f k n x^m (g x)^{-2 m}}{4 e g m^2}-\frac {b f^2 k n x^{2 m} (g x)^{-2 m} \log (x)}{4 e^2 g m}+\frac {b f^2 k n x^{2 m} (g x)^{-2 m} \log ^2(x)}{4 e^2 g}-\frac {f k x^m (g x)^{-2 m} \left (a+b \log \left (c x^n\right )\right )}{2 e g m}-\frac {f^2 k x^{2 m} (g x)^{-2 m} \log (x) \left (a+b \log \left (c x^n\right )\right )}{2 e^2 g}+\frac {b f^2 k n x^{2 m} (g x)^{-2 m} \log \left (e+f x^m\right )}{4 e^2 g m^2}-\frac {b f^2 k n x^{2 m} (g x)^{-2 m} \log \left (-\frac {f x^m}{e}\right ) \log \left (e+f x^m\right )}{2 e^2 g m^2}+\frac {f^2 k x^{2 m} (g x)^{-2 m} \left (a+b \log \left (c x^n\right )\right ) \log \left (e+f x^m\right )}{2 e^2 g m}-\frac {b n (g x)^{-2 m} \log \left (d \left (e+f x^m\right )^k\right )}{4 g m^2}-\frac {(g x)^{-2 m} \left (a+b \log \left (c x^n\right )\right ) \log \left (d \left (e+f x^m\right )^k\right )}{2 g m}-\frac {b f^2 k n x^{2 m} (g x)^{-2 m} \text {Li}_2\left (1+\frac {f x^m}{e}\right )}{2 e^2 g m^2}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.23, size = 302, normalized size = 0.73 \begin {gather*} \frac {(g x)^{-2 m} \left (-2 a e f k m x^m-3 b e f k n x^m+b f^2 k m^2 n x^{2 m} \log ^2(x)-2 b e f k m x^m \log \left (c x^n\right )+2 a f^2 k m x^{2 m} \log \left (f-f x^{-m}\right )+b f^2 k n x^{2 m} \log \left (f-f x^{-m}\right )+2 b f^2 k m x^{2 m} \log \left (c x^n\right ) \log \left (f-f x^{-m}\right )-2 a e^2 m \log \left (d \left (e+f x^m\right )^k\right )-b e^2 n \log \left (d \left (e+f x^m\right )^k\right )-2 b e^2 m \log \left (c x^n\right ) \log \left (d \left (e+f x^m\right )^k\right )-f^2 k m x^{2 m} \log (x) \left (2 a m+b n+2 b m \log \left (c x^n\right )+2 b n \log \left (f-f x^{-m}\right )-2 b n \log \left (1+\frac {f x^m}{e}\right )\right )+2 b f^2 k n x^{2 m} \text {Li}_2\left (-\frac {f x^m}{e}\right )\right )}{4 e^2 g m^2} \end {gather*}
Warning: Unable to verify antiderivative.
[In]
[Out]
________________________________________________________________________________________
Maple [F]
time = 0.10, size = 0, normalized size = 0.00 \[\int \left (g x \right )^{-1-2 m} \left (a +b \ln \left (c \,x^{n}\right )\right ) \ln \left (d \left (e +f \,x^{m}\right )^{k}\right )\, dx\]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Failed to integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 0.38, size = 334, normalized size = 0.81 \begin {gather*} \frac {{\left (2 \, b f^{2} g^{-2 \, m - 1} k m n x^{2 \, m} \log \left ({\left (f x^{m} + e\right )} e^{\left (-1\right )}\right ) \log \left (x\right ) + 2 \, b f^{2} g^{-2 \, m - 1} k n x^{2 \, m} {\rm Li}_2\left (-{\left (f x^{m} + e\right )} e^{\left (-1\right )} + 1\right ) - {\left (b f^{2} k m^{2} n \log \left (x\right )^{2} + {\left (2 \, b f^{2} k m^{2} \log \left (c\right ) + 2 \, a f^{2} k m^{2} + b f^{2} k m n\right )} \log \left (x\right )\right )} g^{-2 \, m - 1} x^{2 \, m} - {\left (2 \, b f k m n e \log \left (x\right ) + 2 \, b f k m e \log \left (c\right ) + {\left (2 \, a f k m + 3 \, b f k n\right )} e\right )} g^{-2 \, m - 1} x^{m} - {\left (2 \, b m n e^{2} \log \left (d\right ) \log \left (x\right ) + {\left (2 \, b m e^{2} \log \left (c\right ) + {\left (2 \, a m + b n\right )} e^{2}\right )} \log \left (d\right )\right )} g^{-2 \, m - 1} + {\left ({\left (2 \, b f^{2} k m \log \left (c\right ) + 2 \, a f^{2} k m + b f^{2} k n\right )} g^{-2 \, m - 1} x^{2 \, m} - {\left (2 \, b k m n e^{2} \log \left (x\right ) + 2 \, b k m e^{2} \log \left (c\right ) + {\left (2 \, a k m + b k n\right )} e^{2}\right )} g^{-2 \, m - 1}\right )} \log \left (f x^{m} + e\right )\right )} e^{\left (-2\right )}}{4 \, m^{2} x^{2 \, m}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F(-2)]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Exception raised: SystemError} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [F]
time = 0.00, size = -1, normalized size = -0.00 \begin {gather*} \int \frac {\ln \left (d\,{\left (e+f\,x^m\right )}^k\right )\,\left (a+b\,\ln \left (c\,x^n\right )\right )}{{\left (g\,x\right )}^{2\,m+1}} \,d x \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________